package com.hiwan.system.pojo;

/**
 * 用户列表
 * Datetime   ： 2013-1-29 下午4:21:33<br>
 * Title      :  UserOrgDeptRole.java<br>
 * Company    :  杭州展鸿科技<br>
 * @author 朱缙伟
 *
 */
public class UserOrgDeptRole{
	
	/**
	 * 用户关系主键
	 */
	private String relationId;
	/**
	 * 用户ID
	 */
	private String userId;
	/**
	 * 用户姓名
	 */
	private String userName;
	/**
	 * 用户身份证类型
	 */
	private String cardType;
	/**
	 * 身份证号码
	 */
	private String cardNo;
	/**
	 * 所属机构id
	 */
	private String orgId;
	/**
	 * 所属部门id
	 */
	private String deptId;
	/**
	 * 任职状态
	 */
	private String status;
	/**
	 * 所拥有的角色拼接
	 */
	private String roleIdstr;
	
	/**
	 * 是否查询下属机构
	 * 0-否，1-是
	 */
	private String isSub;
	
	private String orgName;//用于前台显示
	
	private String deptName;//用于前台显示
	
	private String roles;//用于前台显示
	
	private String[] roleIds;
	

	public String getRoles() {
		return roles;
	}
	public void setRoles(String roles) {
		this.roles = roles;
	}
	public String getDeptName() {
		return deptName;
	}
	public void setDeptName(String deptName) {
		this.deptName = deptName;
	}
	public String getOrgName() {
		return orgName;
	}
	public void setOrgName(String orgName) {
		this.orgName = orgName;
	}
	public String getUserId() {
		return userId;
	}
	public void setUserId(String userId) {
		this.userId = userId;
	}

	public String getCardType() {
		return cardType;
	}
	public void setCardType(String cardType) {
		this.cardType = cardType;
	}
	public String getCardNo() {
		return cardNo;
	}
	public void setCardNo(String cardNo) {
		this.cardNo = cardNo;
	}
	public String getOrgId() {
		return orgId;
	}
	public void setOrgId(String orgId) {
		this.orgId = orgId;
	}
	public String getDeptId() {
		return deptId;
	}
	public void setDeptId(String deptId) {
		this.deptId = deptId;
	}
	
	public String getStatus() {
		return status;
	}
	public void setStatus(String status) {
		this.status = status;
	}
	public String getRoleIdstr() {
		return roleIdstr;
	}
	public void setRoleIdstr(String roleIdstr) {
		this.roleIdstr = roleIdstr;
	}
	
	public String getUserName() {
		return userName;
	}
	public void setUserName(String userName) {
		this.userName = userName;
	}
	public String getRelationId() {
		return relationId;
	}
	public void setRelationId(String relationId) {
		this.relationId = relationId;
	}
	@Override
	public String toString() {
		return "UserOrgDeptRole [relationId=" + relationId + ", userId=" + userId + ", userName=" + userName
				+ ", cardType=" + cardType + ", cardNo=" + cardNo + ", orgId=" + orgId + ", deptId=" + deptId
				+ ", status=" + status + ", roleIdstr=" + roleIdstr + "]";
	}
	public String getIsSub() {
		return isSub;
	}
	public void setIsSub(String isSub) {
		this.isSub = isSub;
	}
	public String[] getRoleIds() {
		return roleIds;
	}
	public void setRoleIds(String[] roleIds) {
		this.roleIds = roleIds;
	}
	@Override
	public int hashCode() {
		return this.userId.hashCode()+this.userName.hashCode();
	}
	@Override
	public boolean equals(Object obj) {
		if(obj instanceof UserOrgDeptRole){
			UserOrgDeptRole uodr=(UserOrgDeptRole)obj;
			return (this.userId.equals(uodr.userId))&&(this.userName.equals(uodr.userName));
         }
         return super.equals(obj);
	}
}
